public class R1 {
    public static void main(String[] args) {
        //完善数组数据
        int[] array = {497, 131, 486, 345, 78, 452, 654, 123, 897, 123};
        //冒泡排序
        for (int i = 0; i < array.length-1; i++) {
            for (int j = i; j < array.length; j++) {
                if (array[j] < array[i]) {
                    int temp = array[j];
                    array[j] = array[i];
                    array[i] = temp;
                }
            }
        }
        //输出数组
        for (int i = 0; i < array.length; i++) {
            System.out.println(array[i]);
        }
    }
}
